import Login from "../pages/Login";
import Layout from "../pages/Layout";
import NotFound from "../pages/NotFound";
import AuthRouter from "../components/AuthRouter";
import index from "./modules";
import order from "./modules/order";
import supplier from "./modules/supplier";
import merchant from "./modules/merchant";
import goods from "./modules/goods";
import promote from "./modules/promote";
import admin from "./modules/admin";

const routes=[
    {
        path:"/",
        name:'主页',
        element:(
            <AuthRouter>
            <Layout></Layout>
          </AuthRouter>
        ),
        children:[index,order,supplier,merchant,goods,promote,admin]
    },

    {
        path:"login",
        element:<Login></Login>
       },
    {
         path:"*",
         element:<NotFound></NotFound>
    },
];
export default routes;